import threading
import time


def test():
    for ii in range(3):
        print(f'线程{threading.current_thread().name}：{ii}正在执行......')


if __name__ == '__main__':
    print('主线程：开始执行......')

    start = time.time()

    items = [threading.Thread(target=test) for i in range(3)]

    for item in items:
        item.start()
        item.join()

    print('主线程：执行结束......')
    print(f'主线程：执行结束，耗时{time.time() - start}秒......')
